module.exports = function () {
  var pathname = location.pathname.substr(1)
  $('.m-index footer li[data-url="' + pathname +'"]').addClass('active').siblings().removeClass('active')

  $('.m-index footer li').on('tap', function () {
    var url = $(this).attr('data-url')
    location.href = $(this).attr('data-url')
  })
}
